package com.shujujiegou;

import java.util.LinkedList;
import java.util.Queue;
import java.util.Stack;

public class MyCircularQueue {
    public static int[] dailyTemperatures(int[] T) {
        int[] t1 = new int[T.length];
        for(int i = 0; i < T.length; ++i) {
            int temp = T[i];
            int j = i + 1;
            while(j < T.length && temp > T[j]) {
                j++;
            }

            if(j == T.length) {
                t1[i] = 0;
                continue;
            }

            t1[i] = j - i;
        }

        return t1;
    }

    public static void main(String[] args) {
        int[] a = {89,62,70,58,47,47,46,76,100,70};
        int [] b = dailyTemperatures(a);
        int c = 0;
    }
}
